import sun.reflect.generics.tree.Tree;

import java.util.Map;
import java.util.Set;
import java.util.TreeMap;
import java.util.TreeSet;

public class Test {
    public static void main(String[] args) {
        Map<String,String> map = new TreeMap<>();
        map.put("卡莎","虚空之女");
        map.put("诺手","诺克萨斯之手");
        map.put("剑魔","亚托克斯");
        map.put("吸血鬼","弗拉基米尔");

       /* System.out.println(map.get("吸血鬼"));
        System.out.println(map.getOrDefault("格温", "不存在"));
        map.remove("吸血鬼");
        System.out.println(map.get("吸血鬼"));
        Set<String> set= map.keySet(); // 获取Key对应的Value
        System.out.println(set);
*/
      /* Set<Map.Entry<String,String>> s = map.entrySet();
       for (Map.Entry<String,String> entry: s) {
           System.out.println("Key : " + entry.getKey() + " Value : " + entry.getValue());
       }*/
       Set<String> set = new TreeSet<>();
       set.add("卡莎");
       set.add("诺手");
       set.add("剑魔");
       set.add("吸血鬼");

        System.out.println(set.contains("格温"));
        set.remove("卡莎");
       System.out.println(set);
    }
}
